Valid for Sitecore
5.3
How can i set "Live" Mode on my site?
Q:
How can I set live mode on my site? By "Live" Mode I mean that all changes are reflected on the site immediately after saving items.
A:
Sitecore supports running a web site directly from the master database. This is similar to viewing a site in the Preview interface. Live Mode is useful for sites with a large base of volatile content where the latest version not restricted by workflow status, item or version publishing restrictions should always be visible. Live Mode is also commonly used for intranet sites.
When running in Live Mode, there is no publishing step:
- Item changes are shown on the live site as soon as they are saved to the database
- Sitecore only displays “publishable” items, where all publishing restrictions including workflow status, item and version visibility are respected
Notice that running in Live mode has caching implications. In general, you cannot cache the output of renderings and web controls when running in Live Mode (the cache is usually cleared when performing publishing operations, but when running in Live Mode users will normally not perform any publishing operations).
Quick-guide to enabling "Live" Mode:
- Find the relevant <site> section and change database="web" to database="master"
- Add a filterItems="true" attribute (for the same <site> section)
- Add an enableWorkflow="true" attribute (still for the same <site> section)
In some setups, you might also have to perform the following two steps
- Copy the <workflowprovider ...> definition from the <database id="master" ...> section to the <database id="web" ...> section
- Modify menu renderings (and other renderings that show lists of items) so that they do not show empty items. Empty items will be present if an item doesn't have any versions that are in a final state of a workflow. You can check for empty items by checking the following condition:
sc:fld('__created',.)!=''